#pragma once

# if defined(TXR_ALGO_DLM_SEGMENT_LIB)
#  define TXR_ALGO_DLM_SEGMENT_EXPORT Q_DECL_EXPORT
# else
#  define TXR_ALGO_DLM_SEGMENT_EXPORT Q_DECL_IMPORT
# endif

#include "txr_algo_dlm_seg_define.h"
#include <QLibrary>

namespace txr_algo_dlm_seg
{
	class TxrAlgoDlmSegImpl;

	class TXR_ALGO_DLM_SEGMENT_EXPORT TxrAlgoDlmSeg
	{
	public:
		TxrAlgoDlmSeg();
		~TxrAlgoDlmSeg();

		tk_bool Load(st_dlm_cfg & cfg);
		void Release();
		tk_bool IsVaild();

		void Detect(st_detect_unit * p_unit, tk_int32 size);

	private:
		DLM_TYPE GetDlmType(st_dlm_cfg & cfg);

	private:
		TxrAlgoDlmSegImpl * m_dlm_obj = TK_NULL_PTR;
		QLibrary * m_lib_dlm = TK_NULL_PTR;
	};
}
//namespace txr_algo_dlm_seg
